//
//  LocationCateoryCell.m
//  DogeLegs
//
//  Created by 宋华 on 2017/9/9.
//  Copyright © 2017年 宋华. All rights reserved.
//

#import "LocationCateoryCell.h"
#import "SignleCateoryCell.h"

@interface LocationCateoryCell () {

}

@property (weak, nonatomic) IBOutlet SignleCateoryCell *locationview;

@property (weak, nonatomic) IBOutlet SignleCateoryCell *cateoryView;


@end

@implementation LocationCateoryCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)setAddress:(NSString *)address {
    if (_address != address) {
        _address = address;
        [self.locationview cellWillDisplay:PostCellType_location labelText:_address];
    }
}

- (void)setCateory:(NSString *)cateory {
    if (_cateory != cateory) {
        _cateory = cateory;
        [self.cateoryView cellWillDisplay:PostCellType_cateory labelText:_cateory];
    }
}

- (void)touchesBegan:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event {
    UITouch *touch = [touches anyObject];
    if (touch.view == _locationview) {
        NSLog(@"location");
    } else if (touch.view == _cateoryView) {
        NSLog(@"cateory");
    }
}

@end
